/*
 *  Copyright (c) 2014-2017. 墨博云舟 All Rights Reserved.
 */

package com.springboot.rmq.comm;


public class Constant {
    /*********commom part*************/
    /**
     * topic字段校验规则
     */

    public static final String TOPIC_PATTEN = "[0-9.:;]+";

    /**
     * 默认搜索的资源名称
     */
    public static final String DEFAULT_RESOURCE_PATTERN = "**/*.class";

    /**
     * 标点符号-逗号
     */
    public static final String PUNCTUATION_COMMA = ",";

    /**
     * 标点符号-句号
     */
    public static final String PUNCTUATION_PERIOD = ".";

    /**
     * 标点符号-下划线
     */
    public static final String PUNCTUATION_UNDERLINE = "_";


    /**
     * group_roder type
     */
    public static final String GROUP_ORDER = "_order";

    /**********Producer Part*****************/
    /**
     * producer配置文件的存放路径
     */
    public static final String PRODUCER_CONFIG_NAME = "message_producer.properties";

    /**
     * nameserver配置项名称com.mobcb.producer.nameserver
     */
    public static final String KEY_PRODUCER_NAMESERVER = "producer_nameserver";

    /**
     * producer组名称
     */

    public static final String KEY_PRODUCER_GROUPNAME = "producer_groupname";

    /**
     * producer topic队列数量
     */

    public static final String KEY_PRODUCER_TOPICQUEUENUMS = "producer_topqueuenums";


    /**
     * producer超时时间，毫秒
     */

    public static final String KEY_PRODUCER_TIMEOUT = "producer_timeoutmils";
    /**
     * instancename
     */
    public static final String KEY_PRODUCER_INSTANCENAME = "producer_instancename";

    /**
     * 同步消息发送失败次数
     */
    public static final String KEY_PRODUCER_RETRYSYNC_TIMES = "producer_syncretry";

    /**
     * 异步消息发送失败次数
     */
    public static final String KEY_PRODUCER_RETRYASYNC_TIMES = "producer_asyncretry";


    /************Consumer Part*************/
    /**
     * consumer超时时间,单位是毫秒
     */
    public static final String KEY_CONSUMER_TIMEOUTMINUTES = "consume_timeoutmils";

    /**
     * consumer扫描路径
     */
    public static final String KEY_CONSUMER_SCANPACKAGE = "consumer_scanpackage";

    /**
     * consumer instance实例名称
     */
    public static final String KEY_CONSUMER_INSTANCE = "consumer_instance";


    /**
     * consumer默认实例名
     */
    //public static final String KEY_CONSUMER_INSTANCE_NAME = "test";


    /**
     * nameserver配置项名称com.mobcb.producer.nameserver
     */
    public static final String KEY_CONSUMER_NAMESERVER = "consumer_nameserver";

    /**
     * 配置项：comsumer.batchmaxsize，每次批量读取的消息个数
     */
    public static final String KEY_CONSUMER_BATCHSIZE = "comsumer_batchmaxsize";

    /**
     * 配置项：comsuer.threadcountmin，最小线程个数
     */
    public static final String KEY_CONSUMER_THREADCOUNTMIN = "comsuer_threadcountmin";

    /**
     * 配置项：comsuer.threadcountmax，最大线程个数
     */
    public static final String KEY_CONSUMER_THREADCOUNTMAX = "comsuer_threadcountmax";

    /**
     * 配置项：com.rocketmq.sendMessageWithVIPChannel，VIP频道发送消息
     */
    public static final String KEY_SEND_MSG_WITH_VIP_CHANNEL = "send_msg_vip_channel";

}
